<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <title>海贝用户协议</title>
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <link rel="stylesheet" href="css/dist/css/bootstrap.min.css" media="screen" title="no title">

    <style>
        body {
            background: #f9f9f9;
        }
        
        header {
            padding: 10px 0;
            background: #fff;
            box-shadow: 2px 2px 4px #ccc;
        }
        
        .haibei-wapper {
            width: 60%;
            margin: 0 auto;
        }
        
        .haibei-footer {
            height: 50px;
            line-height: 50px;
            width: 100%;
            color: #fff;
            background: deepskyblue;
            margin-top: 20px;
        }
        
        h5 {
            line-height: 30px;
        }
        
        .haibei-content {
            margin-top: 10px;
            padding: 15px 0 30px 0;
            line-height: 30px;
            border-radius: 5px;
            background: #fff;
        }
        
        .learn-menu li {
            float: left;
            list-style: none;
        }
        
        .learn-menu li a {
            display: block;
            font-size: 20px;
            padding: 10px 30px;
            text-decoration: none;
            color: #666;
            font-family: '微软雅黑';
            font-weight: 500;
        }
        
        .learn-menu li a.active {
            color: #365c73;
        }
    </style>
</head>

<body>
    <header>
        <div class="haibei-wapper">
            <div class="haibei-logo pull-left">
                <a href=""><img src="images/logo1.png" alt="" style="max-width:200px"></a>
            </div>
            <div class="pull-right learn-menu">
                <ul>
                    <li><a href="javascript:;" class="active" id="stud_01">下载安装</a></li>
                    <li><a href="javascript:;" id="stud_02">使用安装（学员篇）</a></li>
                    <li><a href="javascript:;" id="stud_03">使用安装（讲师篇）</a></li>
                </ul>

            </div>
            <div class="clearfix"></div>
        </div>
    </header>
    <section class="haibei-content haibei-wapper text-center">
        <img src="images/stud_01.jpg" alt="" id="show_img">

    </section>
    <footer class="haibei-footer text-center hidden">
        <span>成都沃单网络科技有限公司</span>
        <span>成都高新区锦城大道666号4栋17层8号</span>
        <span>kefu@haibeiclub.com</span>
    </footer>
</body>

<script>
    window.onload = function () {
        var menu = document.querySelectorAll('.learn-menu ul li');
        var showImg = document.querySelector('#show_img');
        function classB(el) {
            for (var i = 0; i < el.length; i++) {
                el[i].getElementsByTagName('a')[0].className = '';
            }
        }
        for (var i = 0; i < menu.length; i++) {
            menu[i].onclick = function () {
                classB(menu);
                var targetId = this.getElementsByTagName('a')[0];
                targetId.className = 'active';
                showImg.setAttribute('src', 'images/' + targetId.getAttribute('id') + '.jpg');
            }
        }
    }

</script>

</html>